package isssr.dao.interfaces;

import isssr.dao.exception.DAOException;
import isssr.entity.src.ComparisonOperator;
import isssr.entity.src.User;

import java.util.List;
import java.util.Map;

public interface UserDAO {

	public void insert(User user) throws DAOException;
	public void update(User user) throws DAOException;
	public void delete(User user) throws DAOException;
	public Integer getAll(List<User> resultList ) throws DAOException;
	public Integer getAll(List<User> resultList, Map<String, Object> filters, RecordSorting ordering, RecordPagination pagination) throws DAOException;
	public Integer getEligibleSuper(List<User> resultList, User referenceUser)throws DAOException;
	public Integer getEligibleSuper(List<User> resultList, User referenceUser, Map<String, Object> matchingFilter, RecordSorting ordering, RecordPagination pagination) throws DAOException;
	public Integer getEligibleEnactors(List<User> resultList, User referenceUser) throws DAOException;
	public Integer getEligibleEnactors(List<User> resultList, User referenceUser, Map<String, Object> matchingFilter, RecordSorting ordering, RecordPagination pagination) throws DAOException;
	//public List<User> getAllByLevel(User referenceUser, ComparisonOperator operator) throws DAOException;
	//public List<User> getAllByLevel(User referenceUser, ComparisonOperator operator, Map<String, Object> filters, Integer firstResult, Integer pageSize) throws DAOException;
	public User getByAuth(String username, String password) throws DAOException;
	public User getByUsername(String username) throws DAOException;
	
	
	
}
